package com.gk.fein;

import com.eight.pojo.TbCoupon;
import io.swagger.models.auth.In;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

import java.util.List;

/**
 * @author: GK
 * @date: 2023/3/1 9:32
 * @version:No1.0
 */
@FeignClient("rentcar-coupon")
public interface UserEnableCouponFein {

    /**
     * 查询所有优惠卷
     *
     * @return 返回所有优惠卷信息
     */
    @GetMapping("/coupon/userEnableCoupon")
    public List<TbCoupon> getUseEnableCoupon();

    /**
     * 根据优惠券的id查询出一条优惠券记录
     *
     * @param cid 优惠券id
     * @return 查询出现的记录
     */
    @GetMapping("/coupon/getCouponByName/{cid}")
    TbCoupon getCouponByCid(@PathVariable Integer cid);


}
